<template>
  <div class="rankList">
    <div class="rkItem" v-for="(item, index) in rankList" :key="index">
      <div v-if="index == 0" class="itNo1">
        <a href="javascript:void(0);">
          <img :src="item.imgUrl" alt="" />
        </a>
        <p class="rkTime">更新时间:{{ item.updata_time }}</p>
        <div class="count">
          <div class="downIcon"></div>
          <p>{{ item.count }}人下载</p>
        </div>
      </div>
      <div v-else class="itOther">
        <p>
          <span>{{ index + 1 }}</span
          ><a href="javascript:void(0);">{{ item.rankName }}</a>
        </p>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  name: "gl_rank",
  data() {
    return {};
  },
  props: {
    rankList: {},
  },
  components: {},
  methods: {},
  mounted() {},
};
</script>

<style lang="scss" scoped>
.rankList {
  padding-top: 5px;
  .rkItem {
    padding: 10px 0;
    border-bottom: 1px solid #eee;
    .itNo1 {
      max-width: 130px;
      padding: 5px 0;
      p {
        font-size: 12px;
        color: #666;
      }
      .rkTime {
        text-align: center;
        padding-bottom: 5px;
      }
      .count {
        width: 100%;
        height: 24px;
        display: flex;
        align-items: center;
        background-color: #ebebeb;
        border-radius: 50px;
        .downIcon {
          content: "";
          width: 24px;
          height: 24px;
          border-radius: 50%;
          background-image: url("https://css.mafengwo.net/images/gonglve/new-gl-icon6@2x.png");
          background-size: 60px;
          background-position: -20px 60px;
        }
        p {
          padding-left: 6px;
        }
      }
    }
    .itOther {
      p {
        display: flex;
        align-items: center;
        span {
          font-size: 18px;
          color: #ff9d00;
        }
        a {
          font-size: 14px;
          color: #333;
          margin-left: 10px;
          &:hover {
            color: #ff9d00;
            text-decoration: underline;
          }
        }
      }
    }
  }
}
</style>